package com.spark.lola.mapper.statistics;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.spark.lola.statistics.entity.StatisticsProduct;
import com.spark.lola.statistics.entity.StatisticsSupplier;
import com.spark.lola.support.mybatis.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 产品报表 Mapper 接口
 * </p>
 * @author dengyejun
 * @since 2020-05-12
 */
@Mapper
public interface StatisticsProductMapper extends BaseMapper<StatisticsProduct> {
    IPage<StatisticsProduct> page(Page page, @Param("groupType")Integer groupType, @Param(Constants.WRAPPER) Wrapper wrapper);

    List<StatisticsProduct> statistics(@Param("parentId") Long parentId, @Param("start") String start, @Param("end") String end);

    StatisticsProduct findOne(@Param("parentId")Long parentId,@Param("createDate")String createDate);
}
